<!DOCTYPE html>
<html>

<head>
  <meta charset="UTF-8">
  <title>js-template-speed-test</title>
  <style>
    body {
      text-align: center;
      font-family: '宋体';
    }
  </style>
  <script src="lib/highcharts.js"></script>
  <script src="lt.js"></script>
  <script id="lt" type="text/tpl">
    <ul>
      {for $d.list}
      <li>用户: {$v.user}/ 网站：{$v.site}</li>{/for}
    </ul>
  </script>
  <script src="lib/artTemplate.js"></script>
  <script id="artTemplate" type="text/tmpl">
    <ul>
      {{each list as v k}}
      <li>用户: {{v.user}}/ 网站：{{v.site}}</li>{{/each}}
    </ul>
  </script>
  <script src="lib/tmpl.js"></script>
  <script id="tmpl" type="text/tmpl">
    <ul>
      <% for (var val, i = 0, l = list.length; i < l; i ++) { val = list[i]; %>
        <li>用户:
          <%=val.user%>/ 网站：
            <%=val.site%>
        </li>
        <% } %>
    </ul>
  </script>
  <script src="lib/doT.js"></script>
  <script id="doT" type="text/tmpl">
    <ul>
      {{ for (var val, i = 0, l = it.list.length; i
      < l; i ++) { }} {{ val=it.list; }} <li>用户: {{=val[i].user}}/ 网站：{{=val[i].site}}</li>{{ } }}
    </ul>
  </script>
  <script src="lib/juicer.js"></script>
  <script id="juicer" type="text/tmpl">
    <ul>
      {@each list as val}
      <li>用户: $${val.user}/ 网站：$${val.site}</li>
      {@/each}
    </ul>
  </script>
  <script src="lib/mustache.js"></script>
  <script id="Mustache" type="text/tmpl">
    <ul>
      {{#list}}
      <li>用户: {{{user}}}/ 网站：{{{site}}}</li>
      {{/list}}
    </ul>
  </script>
  <script src="lib/handlebars.js"></script>
  <script id="Handlebars" type="text/tmpl">
    <ul>
      {{#list}}
      <li>用户: {{{user}}}/ 网站：{{{site}}}</li>
      {{/list}}
    </ul>
  </script>
  <script src="lib/baiduTemplate.js"></script>
  <script id="baidu-template" type="text/tmpl">
    <ul>
      <% for (var val, i = 0, l = list.length; i < l; i ++) { %>
        <% val = list[i]; %>
          <li>用户:
            <%:=val.user%>/ 网站：
              <%:=val.site%>
          </li>
          <% } %>
    </ul>
  </script>
  <script src="lib/easytemplate.js"></script>
  <script id="easyTemplate" type="text/tmpl">
    <ul>
      <#list data.list as item>
        <li>用户: ${item.user}/ 网站：${item.site}</li>
      </#list>
    </ul>
  </script>
  <script src="lib/underscore.js"></script>
  <script id="underscoreTemplate" type="text/tmpl">
    <ul>
      <% for (var i = 0, l = list.length; i < l; i ++) { %>
        <li>用户:
          <%=list[i].user%>/ 网站：
            <%=list[i].site%>
        </li>
        <% } %>
    </ul>
  </script>
  <script src="lib/etpl.js"></script>
  <script id="etpl" type="text/tmpl">
    <ul>
      <!--for: ${list} as ${val} -->
      <li>用户: ${val.user}/ 网站：${val.site}</li>
      <!--/for-->
    </ul>
  </script>
  <script src="lib/ejs.js"></script>
  <script id="ejs" type="text/tmpl">
    <ul>
      <% for (var i = 0, l = list.length; i < l; i ++) { %>
        <li>用户:
          <%=list[i].user%>/ 网站：
            <%=list[i].site%>
        </li>
        <% } %>
    </ul>
  </script>
  <script src="js/index.js"></script>
</head>

<body>
  <h1>模板引擎ltjs速度测试</h1>
  <h3>ltjs 既小，又快的模板引擎</h3>
  <div id="container"></div>
</body>

</html>